import taichi as ti

ti.init(arch=ti.gpu)

x = ti.field(dtype=ti.f32,shape=10)
y = ti.field(dtype=ti.f32,shape=10)

@ti.kernel
def copy(a:ti.template(),b:ti.template(),c:ti.f32):
    for i in x:
        x[i] = y[i] + c


print(x)
print(y)
copy(x,y,3.0)
print(x)